
class ProductCasesController < ApplicationController

  def index
    @product_cases = ProductCase.all
    @product_cases = @product_cases.where(category_id: params[:category_id]) if params[:category_id]
    @product_cases = @product_cases.where(brand_id: params[:brand_id]) if params[:brand_id]
    @product_cases = @product_cases.paginate(page: params[:page] || 1, per_page: params[:per_page] || 20)
  end

end
